package cn.ecnu.vo.fromFront;

import lombok.Data;

import javax.validation.constraints.Email;
import javax.validation.constraints.NotBlank;
import javax.validation.constraints.Pattern;
import javax.validation.constraints.Size;
import java.util.List;

@Data
public class SupervisorForm {

    @NotBlank
    @Pattern(regexp = "^[A-Za-z_]+$", message = "用户名只能为英文和下划线")
    private String userNickname;

    @NotBlank
    @Pattern(regexp = "^[\\u4E00-\\u9FA5A-Za-z]+$", message = "姓名不合法")
    private String userName;

    @Pattern(regexp = "^(13[0-9]|14[5|7]|15[0|1|2|3|4|5|6|7|8|9]|18[0|1|2|3|5|6|7|8|9])\\d{8}$", message = "手机号码不合法")
    private String userPhone;

    private Integer userGender;

    private Integer userAge;

    @Pattern(regexp = "(^\\d{15}$)|(^\\d{18}$)|(^\\d{17}(\\d|X|x)$)", message = "身份证输入不合法")
    private String userIdentity;

    @Email(message = "邮箱格式不规范")
    private String userEmail;

    @Size(min = 6, message = "密码不得低于6位字符")
    private String userPassword;
    private String userWorkPlace;
    private String userPosition;
    private String supervisorTitle;
    private String supervisorTitleId;
}
